﻿@model MMITWeb.Models.UserProfileViewModel

@{
    ViewBag.Title = "User Profile : Update Profile";

    AjaxOptions ajaxOpts = new AjaxOptions
    {
        UpdateTargetId = "response",
        LoadingElementId = "loading",
        LoadingElementDuration = 2000,
        Url = Url.Action("UpdateUserProfile"),
        Confirm = "Are you sure you want to update your profile?"
    };
}
<style type="text/css">
label, form div.label{
	display:block;
	margin:0px;
	/* color:#ededed; */
	padding:3px 3px 3px 0px; 
	clear:both;
	float: left;
	width: 150px;
	vertical-align: top;
}

label span, div.label span{
	display:inline-block;
	float:left;
	padding:2px 6px 0 0;
	text-align:right;
	width:450px;
	/* font-size:11px; */
	font-weight:normal;
	/* color:#fff; */
}

    </style>
<div id="page" class="container">

<h2>Update Your Profile</h2>

<div id="loading" style="display: none; color:Red; font-weight: bold" >
    <p style="vertical-align:top"><img src="@Url.Content("~/Content/Images/ajax-loader.gif")" alt="loading"/> Loading....</p>
</div>   
<div id="response">

</div>
<fieldset><legend>Profile Data</legend>

@using (Ajax.BeginForm("UpdateUserProfile",ajaxOpts))
{
    @Html.ValidationSummary(true) 
    @Html.EditorForModel()
    <br />@Html.Label("Identification Type")
    <br />@(Html.Telerik().DropDownList().HtmlAttributes(new { style = "width: 250px" })
                                         .Name("IdentificationTypeId")
                                         .BindTo(Model.IdentificationTypes)
                                        )
    <br />@Html.Label("Country")
    <br />@(Html.Telerik().DropDownList().HtmlAttributes(new { style = "width: 250px" })
                                         .Name("CountryId")                                     
                                         .BindTo(Model.Countries)
                                         )

        <p><input type="submit" value="Update Profile" class="t-button t-button-icontext" 
            style="border: none; height: 32px; cursor: pointer; margin-top: 20px; margin-left: 150px;"/></p>  
}

</fieldset>

</div>